package com.tsd.jxc.stock.service;

import com.tsd.core.vo.HlpException;
import com.tsd.core.vo.PageBean;
import com.tsd.jxc.stock.entity.JxcStockTransfer;
import com.tsd.jxc.stock.entity.JxcStockTransferExt;
import com.tsd.system.entity.SysUser;
import com.tsd.system.entity.SysUserExt;

import java.util.List;
import java.util.Map;

/**
 * 描述：JxcStockTransfer服务实现层接口
 *
 * @author Hillpool
 * @date 2022/12/12 11:32:10
 */
public interface JxcStockTransferService {

    /**
     * 描述：根据id获取JxcStockTransfer
     *
     * @param id
     */
    JxcStockTransfer getJxcStockTransferById(Long id) throws Exception;

    /**
     * 描述：根据sid获取JxcStockTransfer
     *
     * @param sid
     */
    JxcStockTransferExt queryBySid(String sid) throws Exception;

    /**
     * 描述：根据sid列表删除JxcStockTransfer
     *
     * @param list
     */
    void deleteJxcStockTransfers(List<String> list, SysUser opUser) throws Exception;

    /**
     * 描述：保存或更新JxcStockTransfer
     *
     * @param record
     * @param opUser
     */
    void saveJxcStockTransfer(JxcStockTransferExt record, SysUser opUser) throws Exception;

    /**
     * 描述：根据params分页查询JxcStockTransfer
     *
     * @param params
     * @param page
     */
    List<JxcStockTransferExt> findJxcStockTransfers(Map<String, Object> params, PageBean page) throws Exception;

    /**
     * 描述：根据params分页查询JxcStockTransfer
     *
     * @param params
     */
    List<JxcStockTransferExt> findJxcStockTransfers(Map<String, Object> params) throws Exception;

    /**
     * 描述：审核/反审
     *
     * @param sidList
     * @param state
     * @param opUser
     */
    void changeJxcStockTransferAuditState(List<String> sidList, Integer state, SysUserExt opUser) throws HlpException;

    /**
     * 描述：同时生成出库单和入库单
     *
     * @param sidList
     * @param opUser
     */
    void genJxcStockTransfers2InAndOutBill(List<String> sidList, SysUserExt opUser) throws Exception;

    /**
     * 描述：导出-含明细
     *
     * @param params
     * @param page
     * @return
     */
    List<JxcStockTransferExt> findJxcStockTransfersIncludeDetail(Map<String, Object> params, PageBean page);
}